package org.adream.account.service;

import java.util.List;

import org.adream.account.aop.annotation.DataSource;
import org.adream.account.dao.DreamBoxUserDao;
import org.adream.account.entity.DreamBoxUserEntity;
import org.adream.account.model.ResultModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
@DataSource("dreamBoxDataSource")
public class DreamBoxUserService {
	
	@Autowired
	private DreamBoxUserDao dreamBoxUserDao;
	
	/**
	 * 老盒子 查询所有用户
	 * 测试用
	 * @return
	 */
	public ResultModel<?> queryAllDreamUser() {
		List<DreamBoxUserEntity> dreamBoxUsers = dreamBoxUserDao.queryAllDreamUser();
		return new ResultModel<List<DreamBoxUserEntity>>(ResultModel.SUCCESS, "查询成功", dreamBoxUsers);
	}
}